package com.hl.controller.Test;


import com.hl.domain.Test.HeartMark;
import com.hl.service.Test.HeartMarkService;
import com.hl.util.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/heartMark")
public class HeartMarkController {
    @Autowired
    private HeartMarkService heartMarkService;
    @GetMapping("/all")
    public R findAll(){
        List<HeartMark> heartMarkList = heartMarkService.findAll();
        if (heartMarkList != null){
            return R.success(heartMarkList);
        }else {
            return R.fail("查询失败");
        }
    }
}
